package cbfz;
import java.sql.*;
public class DBConnection {
	public static Connection getConnection(){
		Connection con=null;
		String url1="jdbc:odbc:cbfz";
		String username="a";
		String password="987654321";
		try{
			Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
			con=DriverManager.getConnection(url1,username,password);
		}
		catch(SQLException e){
			e.printStackTrace();
		}
		catch(ClassNotFoundException e){
			e.printStackTrace();
		}
		return con;
	}
	public static void main(String[] args) {
		Connection con =null;
		con=DBConnection.getConnection();
		if (con==null)
		System.out.println("sddsdd");
		else
			System.out.println("hahahahahad");
	}

}
